package com.kashow.bean.live.follows;

import android.text.TextUtils;

import com.kashow.bean.BaseBean;

/**
 * Created by yybs on 16/11/3.
 */

public class Live extends BaseBean {


    /**
     * _id : 11
     * title : 学海无涯-子分类2
     * desc : 在线直播演示
     * startAt : 2016-10-24 10:46:31
     * price : 1
     * score : 1
     * liveSharePic : http://oss.kashowvr.com/test/10.jpeg
     * livePic : http://oss.kashowvr.com/test/10.jpeg
     * teacher : {"_id":1,"userName":"老师","openid":"ohHipv3s4me1xn_j-AIaPb_bEBd0","phone":"15221441952","wxUserInfo":{"openid":"ohHipv3s4me1xn_j-AIaPb_bEBd0","nickname":"雪花","sex":2,"city":"崇左","province":"广西","country":"中国","headimgurl":"http://wx.qlogo.cn/mmopen/PxpCwCeBADPsn6PvP65icDkY7XLv8B5Bk5BcHggwPdZtavVBM1KcBSAKnHOaHFyeeSTWGl47j3RiaYjXVX2QzDq8lhQVKyFqMn/0","updatedAt":"2016-09-18T08:19:24.000Z"},"createdAt":"2016-10-24T02:46:31.956Z","isSub":false,"sex":0,"balance":0,"score":0,"level":1,"isTeacher":true,"__v":0}
     * teacherName : 老师
     * stream : z1.kashowvr.teststream
     * playUrl : http://pili-live-hls.kashowvr.com/kashowvr/teststream.m3u8
     * category : 14
     * priority : 1
     * createdAt : 2016-10-24T02:46:32.678Z
     * watch : 0
     * status : 1
     * __v : 0
     * id : 11
     */

    private int _id;
    private String title;
    private String desc;
    private String startAt;
    private int price;
    private double score;
    private String liveSharePic;
    private String livePic;
    private boolean reserved;
    /**
     * _id : 1
     * userName : 老师
     * openid : ohHipv3s4me1xn_j-AIaPb_bEBd0
     * phone : 15221441952
     * wxUserInfo : {"openid":"ohHipv3s4me1xn_j-AIaPb_bEBd0","nickname":"雪花","sex":2,"city":"崇左","province":"广西","country":"中国","headimgurl":"http://wx.qlogo.cn/mmopen/PxpCwCeBADPsn6PvP65icDkY7XLv8B5Bk5BcHggwPdZtavVBM1KcBSAKnHOaHFyeeSTWGl47j3RiaYjXVX2QzDq8lhQVKyFqMn/0","updatedAt":"2016-09-18T08:19:24.000Z"}
     * createdAt : 2016-10-24T02:46:31.956Z
     * isSub : false
     * sex : 0
     * balance : 0
     * score : 0
     * level : 1
     * isTeacher : true
     * __v : 0
     */

    private TeacherBean teacher;
    private String teacherName;
    private String stream;
    private String playUrl;
    private int category;
    private int priority;
    private String createdAt;
    private int watch;
    private int status;
    private int __v;
    private String id;

    public int get_id() {
        return _id;
    }

    public void set_id(int _id) {
        this._id = _id;
    }

    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    public String getDesc() {
        return desc;
    }

    public void setDesc(String desc) {
        this.desc = desc;
    }

    public String getStartAt() {
        return startAt;
    }

    public void setStartAt(String startAt) {
        this.startAt = startAt;
    }

    public int getPrice() {
        return price;
    }

    public void setPrice(int price) {
        this.price = price;
    }

    public double getScore() {
        return score;
    }

    public void setScore(double score) {
        this.score = score;
    }

    public String getLiveSharePic() {
        return liveSharePic;
    }

    public void setLiveSharePic(String liveSharePic) {
        this.liveSharePic = liveSharePic;
    }

    public String getLivePic() {
        return livePic;
    }

    public void setLivePic(String livePic) {
        this.livePic = livePic;
    }

    public TeacherBean getTeacher() {
        return teacher;
    }

    public void setTeacher(TeacherBean teacher) {
        this.teacher = teacher;
    }

    public String getTeacherName() {
        return teacherName;
    }

    public void setTeacherName(String teacherName) {
        this.teacherName = teacherName;
    }

    public String getStream() {
        return stream;
    }

    public void setStream(String stream) {
        this.stream = stream;
    }

    public String getPlayUrl() {
        return playUrl;
    }

    public void setPlayUrl(String playUrl) {
        this.playUrl = playUrl;
    }

    public int getCategory() {
        return category;
    }

    public void setCategory(int category) {
        this.category = category;
    }

    public int getPriority() {
        return priority;
    }

    public void setPriority(int priority) {
        this.priority = priority;
    }

    public String getCreatedAt() {
        return createdAt;
    }

    public void setCreatedAt(String createdAt) {
        this.createdAt = createdAt;
    }

    public int getWatch() {
        return watch;
    }

    public void setWatch(int watch) {
        this.watch = watch;
    }

    public int getStatus() {
        return status;
    }

    public void setStatus(int status) {
        this.status = status;
    }

    public int get__v() {
        return __v;
    }

    public void set__v(int __v) {
        this.__v = __v;
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public boolean isReserved() {
        return reserved;
    }

    public void setReserved(boolean reserved) {
        this.reserved = reserved;
    }

    public static class TeacherBean {
        private int _id;
        private String userName;
        private String nickname;
        private String openid;
        private String phone;
        /**
         * openid : ohHipv3s4me1xn_j-AIaPb_bEBd0
         * nickname : 雪花
         * sex : 2
         * city : 崇左
         * province : 广西
         * country : 中国
         * headimgurl : http://wx.qlogo.cn/mmopen/PxpCwCeBADPsn6PvP65icDkY7XLv8B5Bk5BcHggwPdZtavVBM1KcBSAKnHOaHFyeeSTWGl47j3RiaYjXVX2QzDq8lhQVKyFqMn/0
         * updatedAt : 2016-09-18T08:19:24.000Z
         */

        private WxUserInfoBean wxUserInfo;
        private String createdAt;
        private boolean isSub;
        private int sex;
        private int balance;
        private float score;
        private int level;
        private String headimgurl;
        private boolean isTeacher;

        public int get_id() {
            return _id;
        }

        public void set_id(int _id) {
            this._id = _id;
        }

        public String getUserName() {
            return userName;
        }

        public void setUserName(String userName) {
            this.userName = userName;
        }

        public String getOpenid() {
            return openid;
        }

        public void setOpenid(String openid) {
            this.openid = openid;
        }

        public String getPhone() {
            return phone;
        }

        public void setPhone(String phone) {
            this.phone = phone;
        }

        public WxUserInfoBean getWxUserInfo() {
            return wxUserInfo;
        }

        public void setWxUserInfo(WxUserInfoBean wxUserInfo) {
            this.wxUserInfo = wxUserInfo;
        }

        public String getCreatedAt() {
            return createdAt;
        }

        public void setCreatedAt(String createdAt) {
            this.createdAt = createdAt;
        }

        public boolean isIsSub() {
            return isSub;
        }

        public void setIsSub(boolean isSub) {
            this.isSub = isSub;
        }

        public int getSex() {
            return sex;
        }

        public void setSex(int sex) {
            this.sex = sex;
        }

        public int getBalance() {
            return balance;
        }

        public void setBalance(int balance) {
            this.balance = balance;
        }

        public float getScore() {
            return score;
        }

        public void setScore(float score) {
            this.score = score;
        }

        public int getLevel() {
            return level;
        }

        public void setLevel(int level) {
            this.level = level;
        }

        public boolean isIsTeacher() {
            return isTeacher;
        }

        public void setIsTeacher(boolean isTeacher) {
            this.isTeacher = isTeacher;
        }


        public String getNickname() {
            if (TextUtils.isEmpty(nickname) && wxUserInfo!= null) {
                nickname = wxUserInfo.getNickname();
            }
            return nickname;
        }

        public void setNickname(String nickname) {
            this.nickname = nickname;
        }

        public String getHeadimgurl() {
            if (TextUtils.isEmpty(headimgurl) && wxUserInfo != null) {
                headimgurl = wxUserInfo.getHeadimgurl();
            }
            return headimgurl;
        }

        public void setHeadimgurl(String headimgurl) {
            this.headimgurl = headimgurl;
        }

        public static class WxUserInfoBean {
            private String openid;
            private String nickname;
            private int sex;
            private String city;
            private String province;
            private String country;
            private String headimgurl;
            private String updatedAt;

            public String getOpenid() {
                return openid;
            }

            public void setOpenid(String openid) {
                this.openid = openid;
            }

            public String getNickname() {
                return nickname;
            }

            public void setNickname(String nickname) {
                this.nickname = nickname;
            }

            public int getSex() {
                return sex;
            }

            public void setSex(int sex) {
                this.sex = sex;
            }

            public String getCity() {
                return city;
            }

            public void setCity(String city) {
                this.city = city;
            }

            public String getProvince() {
                return province;
            }

            public void setProvince(String province) {
                this.province = province;
            }

            public String getCountry() {
                return country;
            }

            public void setCountry(String country) {
                this.country = country;
            }

            public String getHeadimgurl() {
                return headimgurl;
            }

            public void setHeadimgurl(String headimgurl) {
                this.headimgurl = headimgurl;
            }

            public String getUpdatedAt() {
                return updatedAt;
            }

            public void setUpdatedAt(String updatedAt) {
                this.updatedAt = updatedAt;
            }
        }
    }
}
